In a java swing program embedded in an application of Adobe Flex, the communication between the client Adobe Flex and the java swing is generally carried out by using javascript. In existing applications, since the communication between the Adobe Flex and the java swing basically involves small data, the data processing capability of javascript can guarantee a normal communication between the Adobe Flex and the java swing.
In a prior art, the Adobe Flex is used to draw graphs to interact with a user, while the java swing is used to extract data from a database. After the Adobe Flex acquires a drawing command, according to the drawing command, the data of all intervals corresponding to the drawing command would be acquired from the java swing, and then the Adobe Flex will, according to the data, draws the graph of an interval selected by a user. Thus, the Adobe Flex acquires all data through one communication, which has advantages of fewer interaction with the java swing and timely graphics rendering.
In the prior art, with the increase of the data required in displaying a graph, due to the limitation of the data processing capability of javascript, the Adobe Flex has to spend more time on acquiring the drawing data, which leads to an obviously slow speed of drawing a graph; therefore, in the case of increased drawing data, the data processing capability of javascript can easily become the bottleneck of the overall communication.